<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<title>Example 5 (RTMP) - 1 stream with a pre, mid and post-roll</title>
<script type="text/javascript" src="../dist/jquery-1.3.1.js"></script>
<script type="text/javascript" src="../dist/flowplayer-3.1.4.min.js"></script>
<link rel="stylesheet" type="text/css" href="css/global.css" />
</head>
<body>

<h2>Example 5 (RTMP) - 1 stream with a pre, mid and post-roll</h2>
<p class="example">
1 show stream limited to 20 seconds in duration with a pre-roll, mid roll (10 seconds into the show stream) 
and a post-roll ad. The mid-roll has a companion banner attached.
</p>
<div id="container">
  <div id="player_row">
     <div id="player_left">
    <a class="example"></a>
   </div>
   <div id="player_right">
    <div id="companion">
      A COMPANION ADVERTISEMENT WILL APPEAR IN HERE
    </div>
   </div>
  </div>
</div>

<script type="text/javascript">
flowplayer("a.example", "../dist/flowplayer-3.1.5.swf", {
    plugins: {
        rtmp: {
            url: "../dist/flowplayer.rtmp-3.1.3.swf"
        },
        rtmpInstream: {
            url: "../dist/flowplayer.rtmp-3.1.3.swf"
        },
        controls: {
            autoHide: "always"
        },

        openAdStreamer: {
            url: '../dist/OpenAdStreamer.swf',
//            "url": "/fp-http/OpenAdStreamer.swf",
           
            "shows": {
            "baseURL": "rtmp://ne7c0nwbit.rtmphost.com/videoplayer",
              "streams": [
                    { "file":"mp4:the-black-hole.mp4", "duration":"00:00:20" }
               ]
            },

            "ads": {
                "servers": [
                    {
                       "type": "OpenX",
                       "apiAddress": "http://openx.openvideoads.org/openx/www/delivery/fc.php"
                    }
                ],
            "displayCompanions": true,
            "companions": [
                    { "id":"companion", "width":"150", "height":"360" }
            ],

              "schedule": [
               {
                  "zone": "1",
                  "position": "pre-roll",
                  "playOnce": true
               },
               {
                  "zone": "4",
                  "position": "mid-roll",
                  "startTime": "00:00:10",
                  "playOnce": true
               },
               {
                  "zone": "1",
                  "position": "post-roll",
                  "playOnce": true
               }
              ]
            },

            "debug": {
              "levels": "fatal",
              "debugger": "firebug"
            }
        }
    }
});
</script>
<p>
The configuration for this example is:
</p>
<div class="codebox">
<pre>
<code class="javascript">
flowplayer("a.example", "../dist/flowplayer-3.1.5.swf", {
    plugins: {
        rtmp: {
            url: "../dist/flowplayer.rtmp-3.1.3.swf"
        },
        rtmpInstream: {
            url: "../dist/flowplayer.rtmp-3.1.3.swf"
        },
        controls: {
            autoHide: "always"
        },

        openAdStreamer: {
            url: '../dist/OpenAdStreamer.swf',

            "shows": {
                "baseURL": "rtmp://ne7c0nwbit.rtmphost.com/videoplayer",
                "streams": [
                    { "file":"mp4:the-black-hole.mp4", "duration":"00:00:20" }
                ]
            },

            "ads": {
                "servers": [
                    {
                       "type": "OpenX",
                       "apiAddress": "http://openx.openvideoads.org/openx/www/delivery/fc.php"
                    }
                ],
               "displayCompanions": true,
               "companions": [
                   { "id":"companion", "width":"150", "height":"360" }
               ],
               "schedule": [
                  {
                     "zone": "1",
                     "position": "pre-roll",
                     "playOnce": true
                  },
                  {
                     "zone": "4",
                     "position": "mid-roll",
                     "startTime": "00:00:10",
                     "playOnce": true
                  },
                  {
                     "zone": "1",
                     "position": "post-roll",
                     "playOnce": true
                  }
               ]
            },

            "debug": {
               "levels": "fatal",
               "debugger": "firebug"
            }
        }
    }
});
</code>
</pre>
</div>
<script type="text/javascript" src="js/tracking.js">
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-10158120-3");
if(TRACKING_TURNED_ON) {
	pageTracker._trackPageview();
}
} catch(err) {}
</script>
</body>
</html>